package com.rd.student.jiaji.class3.wangyanbo.day0801;

import java.util.Arrays;

public class Test {
    public static void main(String[] args) {
        int[] arr=new int[]{1,3,5,7,9,11,13,15,17,0};
        for (int i = 0; i < arr.length; i++) {
            if (arr[i]==0){
                arr[i]=10;
            }
        }
        Arrays.sort(arr);
        System.out.println(Arrays.toString(arr));




        int[] arr1=new int[]{1,3,5,7,9,11,13,15,17};
        int[] arr2=new int[arr1.length];
        int i=5;
                System.arraycopy(arr1,0,arr2,0,i);
                System.arraycopy(arr1,i+1,arr2,i,arr2.length-i-1);
        System.out.println(Arrays.toString(arr2));
    }
}
